/*
 ------------------------------------------------------------------------------
 Copyright (C) 2013 Eternal Games.

 This file is part of the GLQuake source code.

 The GLQuake source code is free software; you can redistribute it and/or
 modify it under the terms of the GNU General Public License as published by
 the Free Software Foundation; either version 2 of the License, or (at your
 option) any later version.

 The GLQuake source code is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
 or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
 more details.

 You should have received a copy of the GNU General Public License along with
 the GLQuake source code; if not, write to the Free Software Foundation, Inc.,
 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 ------------------------------------------------------------------------------
*/


//
// table.h - framework used by dynamic-link libraries
//


#ifndef __FRAMEWORK_TABLE_H__
#define __FRAMEWORK_TABLE_H__


/*
 ==============================================================================

 Lookup Tables:

 Tables are used to map a floating point input value to a floating point output
 value, with optional wrap / clamp and interpolation.

 ==============================================================================
*/

// Functions exported by the engine
struct glqTable_t {
	// Finds a table with the given name. Returns -1 if not found.
	int						(*FindTable)(const char *name);

	// Performs a lookup in the given table with the given index
	float					(*LookupTable)(int tableIndex, float lookupIndex);
};


#endif	// __FRAMEWORK_TABLE_H__